<%--
  Created by IntelliJ IDEA.
  User: 竹康乐
  Date: 2022/11/9
  Time: 14:21
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>操作失败</title>
    <style>
        body{
            text-align: center;
        }
        h2{
            text-align: center;
            color: red;
            margin-top: 20px;
        }
        button{
            background-color: coral;
            color: white;
            width: 80px;
            height: 30px;
            border-radius: 5px;
            font-size: 15px;
            border: white;
            margin: 20px;
        }
    </style>
</head>
<body>
<h2>${requestScope.errorMsg}，请重试</h2>
<button onclick="back()">返回</button>
<button onclick="main()">回首页</button>
<script>
    function back() {
        //window返回上一级历史记录
        window.history.back();
    }
    function main() {
        //浏览器重定向首页
        window.location.href="/main";

    }

</script>

</body>
</html>

